package com.dp.system.domain;

import java.util.List;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.dp.common.annotation.Excel;
import com.dp.common.core.domain.BaseEntity;

/**
 * 报警记录对象 sys_alarm_log
 * 
 * @author ruoyi
 * @date 2025-02-10
 */
public class SysAlarmLog extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 报警记录ID */
    private Long logId;

    /** 规则ID */
    @Excel(name = "规则ID")
    private Long ruleId;

    /** 大棚ID */
    private Long greenhouseId;


    private String greenhouseName; // 新增大棚名称字段

    /** 温度记录ID */
    @Excel(name = "温度记录ID")
    private Long temperatureId;

    /** 报警消息 */
    @Excel(name = "报警消息")
    private String alarmMessage;

    /** 报警时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "报警时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date alarmTime;

    /** 报警记录信息 */
    private List<SysAlarmLog> sysAlarmLogList;

    public void setLogId(Long logId) 
    {
        this.logId = logId;
    }

    public Long getLogId() 
    {
        return logId;
    }
    public void setRuleId(Long ruleId) 
    {
        this.ruleId = ruleId;
    }

    public Long getRuleId() 
    {
        return ruleId;
    }
    public void setGreenhouseId(Long greenhouseId) 
    {
        this.greenhouseId = greenhouseId;
    }

    public Long getGreenhouseId() 
    {
        return greenhouseId;
    }
    public void setTemperatureId(Long temperatureId) 
    {
        this.temperatureId = temperatureId;
    }

    public String getGreenhouseName() {
        return greenhouseName;
    }
    public void setGreenhouseName(String greenhouseName) {
        this.greenhouseName = greenhouseName;
    }

    public Long getTemperatureId() 
    {
        return temperatureId;
    }
    public void setAlarmMessage(String alarmMessage) 
    {
        this.alarmMessage = alarmMessage;
    }

    public String getAlarmMessage() 
    {
        return alarmMessage;
    }
    public void setAlarmTime(Date alarmTime) 
    {
        this.alarmTime = alarmTime;
    }

    public Date getAlarmTime() 
    {
        return alarmTime;
    }

    public List<SysAlarmLog> getSysAlarmLogList()
    {
        return sysAlarmLogList;
    }

    public void setSysAlarmLogList(List<SysAlarmLog> sysAlarmLogList)
    {
        this.sysAlarmLogList = sysAlarmLogList;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("logId", getLogId())
            .append("ruleId", getRuleId())
            .append("greenhouseId", getGreenhouseId())
            .append("temperatureId", getTemperatureId())
            .append("alarmMessage", getAlarmMessage())
            .append("alarmTime", getAlarmTime())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .append("sysAlarmLogList", getSysAlarmLogList())
            .toString();
    }
}
